common: cli: avoid memory leak
authorPeng Fan <[email protected]>
Tue, 22 Dec 2015 09:14:13 +0000 (17:14 +0800)
committerTom Rini <[email protected]>
Mon, 4 Jan 2016 17:25:35 +0000 (12:25 -0500)
commit09a788624dbe32aeeb0d74c97c0965303eb96d8c
tree4cdba3e789223ca57cfa2e791fe247982d1a146d
parenta40b2dff7bec6c1656a59ce31c16207b8954eb68
common: cli: avoid memory leak

Whether CONFIG_SYS_HUSH_PARSER is defined or not, should always
check to free 'buff' to avoid memory leak.

Signed-off-by: Peng Fan <[email protected]>
Cc: Tom Rini <[email protected]>
Cc: Masahiro Yamada <[email protected]>
Cc: Simon Glass <[email protected]>
common/cli.c